package com.woniuxy.myfinance.service.ServiceImpl;

import com.woniuxy.commons.entity.Finance;

import com.woniuxy.myfinance.mapper.FinanceMapper;
import com.woniuxy.myfinance.service.FinanceService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author author
 * @create 2021-11-16 12:06
 */
@Service
public class FinanceServiceImpl implements FinanceService {

    @Resource
    private FinanceMapper financeMapper;




    @Override
    public void addFinance(Finance finance) {
    financeMapper.addFinance(finance);
    }

    @Override
    public void updateFinance(Finance finance) {
       financeMapper.updateFinance(finance);
    }

    @Override
    public List<Finance> selectAllFinance(Finance finance, Integer pageIndex, Integer pageSize) {
        return financeMapper.selectAllFinance(finance, pageIndex, pageSize);
    }

    @Override
    public int selectFinanceCountBylimit(Finance finance) {
        return financeMapper.selectFinanceCountBylimit(finance);
    }

    @Override
    public void delectFinanceByid(int financeid) {
           financeMapper.delectFinanceByid(financeid);
    }
}
